#!/usr/bin/env bash

IMAGE_TO_RUN=${DEVEL_IMAGE_NAME:-zetton/trajectory-simulator:24.01}

docker stop tra-simulator || true
docker rm tra-simulator || true

# remove nvidia-related args when running in pure CPU environment

docker run -it -d \
  --name tra-simulator \
  --ipc=host \
  --volume="$(dirname ${PWD}):/workspace" \
  --cap-add=SYS_PTRACE --security-opt seccomp=unconfined \
  ${IMAGE_TO_RUN}

